﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.ComponentModel;
using System.Windows;
using clf.weighing.entity;

namespace weighing
{
    public class StatusBarData : INotifyPropertyChanged
    {
        public event PropertyChangedEventHandler PropertyChanged;



        private List<SimpleMessage> _runMessage;

        public List<SimpleMessage> RunMessages
        {
            get { return _runMessage; }
            set
            {
                _runMessage = value;
                PropertyChanged?.Invoke(this, new PropertyChangedEventArgs(nameof(RunMessages)));
                PropertyChanged?.Invoke(this, new PropertyChangedEventArgs(nameof(NoReads)));
            }
        }


        public int NoReads
        {
            get { return RunMessages.Count; }
        }

    }
}
